<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html >
<%@ include file = "lianjie.jsp" %>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
	<%
		Object ISBN = session.getAttribute("ISBN");
		request.setCharacterEncoding("utf-8");
 		String bookname_m = request.getParameter("bookname");
		String author = request.getParameter("author");
		String type = request.getParameter("type");
		String press = request.getParameter("press");
		float price = Float.parseFloat(request.getParameter("price"));
		int surplus = Integer.parseInt(request.getParameter("surplus"));
		String sql = "update booksmassage set name = '" + bookname_m + "' , author = '" + author
				+ "' , type = '" + type + "' , press = '" + press + "',price = "+price+",surplus = "+surplus+" where ISBN = '" + ISBN + "'";
		out.print(sql);
		try {
			stmt.executeUpdate(sql);
			out.println("修改成功");
			response.setHeader("Refresh", "1;URL=modify_book.jsp");
		} catch (SQLException e) {
			out.println("错误提示：" + e.getMessage());
		} finally {
			stmt.close();
			conn.close();
		}
		
	%>
</body>
</html>